var INTRODUCE = function() 
{
	var o = {};
	
	o.run = function()
	{
		o.detailcheck();
		o.commentcheck();
		o.commentcount();
	}
	//显示商品详情模块
	o.detailcheck = function(){
		
		$.post('/Api/Item/check' , {id:id} , function(ret){
			if( ret.status == true){
				template.config("escape",   false);
				var html = template('detail-list-tpl' , ret);
				$('#details-show').append(html);;
			}
		});
	}
	//购物车添加
	o.shopcarclick = function(){
		var cart_num	= $('#text_box').val();
		var ware_cart1	= $('#ware_cart1').html();
		var cart_list1	= $('#ware_cart1').next().find('.selected').html();
		
		$.post('/Api/Item/add' , { id:id , cart_num:cart_num , ware_cart1:ware_cart1 
			, cart_list1:cart_list1} , function(ret){
			if( ret.count == 0){
				alert(ret.data);
				window.location.href=window.location.href;
			}
			else{
				if( ret.count == 2){
					alert(ret.data);
				}
				else if( ret.count == 1){
					alert(ret.data);
				}
			}
		});
		
		
	}
	
	//显示评价模块
	o.commentcheck = function(){
		
		$.post('/Api/Item/commentlist' , {id:id} , function(ret){
			if( ret.status == true){
				template.helper('dateFormat', function(time){
					return getLocalTime(time);
				});
				template.config("escape",   false);
				var html = template('comment-list-tpl' , ret);
				$('#comment-show').append(html);;
			}
		});
	}
	
	//显示评价统计数模块
	o.commentcount = function(){
		
		$.post('/Api/Item/commentcount' , {id:id} , function(ret){
			if( ret.status == true){
				template.config("escape",   false);
				var html = template('comment-count-tpl' , ret);
				$('#comment-count-show').append(html);;
			}
		});
	}
	
	return o;
}();




